<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, target-densitydpi=device-dpi"
          name="viewport">
    <link rel="stylesheet" type="text/css" href="/js/plugins/qianbao/reset.css">
    <link rel="stylesheet" href="/js/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="/css/reset.css">
    <link rel="stylesheet" href="/css/register.css">
    <link rel="stylesheet" href="/css/font/css/font-awesome.min.css">
    <link rel="stylesheet" href="js/plugins/dialog2/dialog.css">
    <link rel="stylesheet" type="text/css" href="/js/plugins/qianbao/weichat.css">
    <script src="/js/jquery/jquery.min.js"></script>
    <script src="/js/bootstrap/js/bootstrap.min.js"></script>
    <script src="/js/plugins/jquery-form/jquery.form.js"></script>
    <script src="/js/plugins/jquery-validation/jquery.validate.min.js"></script>
    <script src="/js/plugins/jquery-validation/messages/messages_cn.js"></script>
    <script src="/js/plugins/dialog2/dialog.min.js"></script>
    <title>My Wallet</title>
</head>
<body>
<script>
    $(function () {
        var user = JSON.parse(sessionStorage.getItem('user'));
        console.log(user);
        var userId = user.id;
        $.get("/mymoneys/" + userId, function (data) {
            console.log(data.money);
            $("#lingqian").html( data.money + "元");
        })

    })


</script>
<div class="wrap">
    <div class="top-bar">
        <div class="goback"><a href="qianbao_index.html"><img
                src="http://www.17sucai.com/preview/1202/2018-08-12/wallet/img/fh.png"></a></div>
        <h1>零钱</h1>
        <div class="wallet-more">零钱明细</div>

    </div>
    <div class="wallet-content">
        <div class="wallet-box">
            <img src="http://www.17sucai.com/preview/1202/2018-08-12/wallet/img/aq.png">
            <h2>我的零钱</h2>
            <h3 id="lingqian">￥20.58</h3>
            <button class="in-int">充值</button>
            <button class="out">提现</button>
            <p>你有零钱理财资产，点击查看详情</p>
        </div>
    </div>
</div>
<div class="bottom">
    <p class="qs">常见问题</p>
    <p class="ser">本服务由财付通提供</p>
</div>
<script type="text/javascript">
    window.onload = function () {
        var getOut = document.getElementsByClassName("out")[0];
        getOut.onclick = function () {
            window.location.href = "/tixian.html";
        };
        var getOut = document.getElementsByClassName("in-int")[0];
        getOut.onclick = function () {
            window.location.href = "/congzhi.html";
        };
    };
</script>
</body>
</html>